﻿using System;
using System.Collections.Generic;
using System.Data.Entity.ModelConfiguration;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using ZSZ.Service.Entity;

namespace ZSZ.Service.EntityConfig
{
    class CommunityConfig: EntityTypeConfiguration<CommunitiesEntity>
    {
        public CommunityConfig() {
            this.ToTable("T_Communities");
            this.HasRequired(c => c.Region).WithMany().HasForeignKey(a=>a.RegionId);
        }
    }
}
